Alexa Skills Projects by Madhur Bhargava
Author:Madhur Bhargava
Language: eng
Format: epub
Tags: COM067000 - COMPUTERS / Hardware / General, COM074000 - COMPUTERS / Hardware / Mobile Devices, COM025000 - COMPUTERS / Expert Systems
Publisher: Packt Publishing
Published: 2018-07-02T07:43:24+00:00
if ("Answer" === intentName) {
handleAnswerRequest(intent, session, callback);
} else if ("AMAZON.StopIntent" === intentName) {
handleFinishSessionRequest(intent, session, callback);
} else {
throw "Invalid intent";
}
}
We shall first see the simpler of the two, which is AMAZON.StopIntent, raised once the user decides to prematurely end the skill's execution by saying a phrase such as "Alexa, Stop Factly." This causes handleFinishSessionRequest to be called:
function handleFinishSessionRequest(intent, session, callback) {
callback(session.attributes,
buildSpeechletResponse("Factly will Exit. Good bye!", "", true));
}
This says a goodbye phrase to the user before the Factly Skill exits.
The Answer intent request is a significantly more complicated one, as it has multiple information flow paths and is handled by the handleAnswerRequest method:
function handleAnswerRequest(intent, session, callback) {
var speechOutput = "";
var sessionAttributes = {};
var gameInProgress = session.attributes && session.attributes.questions;
var answerSlotValid = isAnswerSlotValid(intent);
var userGaveUp = intent.name === "DontKnowIntent";
Download
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
Computer Vision & Pattern Recognition | Expert Systems |
Intelligence & Semantics | Machine Theory |
Natural Language Processing | Neural Networks |
Algorithms of the Intelligent Web by Haralambos Marmanis;Dmitry Babenko(7873)
Hadoop in Practice by Alex Holmes(5668)
Jquery UI in Action : Master the concepts Of Jquery UI: A Step By Step Approach by ANMOL GOYAL(5526)
Life 3.0: Being Human in the Age of Artificial Intelligence by Tegmark Max(4530)
Functional Programming in JavaScript by Mantyla Dan(3730)
The Age of Surveillance Capitalism by Shoshana Zuboff(3437)
Big Data Analysis with Python by Ivan Marin(3136)
Blockchain Basics by Daniel Drescher(2902)
The Rosie Effect by Graeme Simsion(2723)
Test-Driven Development with Java by Alan Mellor(2651)
WordPress Plugin Development Cookbook by Yannick Lefebvre(2634)
Hands-On Machine Learning for Algorithmic Trading by Stefan Jansen(2556)
Data Augmentation with Python by Duc Haba(2502)
Applied Predictive Modeling by Max Kuhn & Kjell Johnson(2495)
Dawn of the New Everything by Jaron Lanier(2446)
The Infinite Retina by Robert Scoble Irena Cronin(2319)
Principles of Data Fabric by Sonia Mezzetta(2310)
The Art Of Deception by Kevin Mitnick(2309)
Rapid Viz: A New Method for the Rapid Visualization of Ideas by Kurt Hanks & Larry Belliston(2208)